package main

import "fmt"

/**
声明一个泛型函数
**/
func main() {
	ints := []int{1, 2, 3, 4, 5}
	strings := []string{"helllo", "world", "go", "wc"}
	printlenSlice[string](strings)
	printlenSlice[int](ints)
}

func printlenSlice[T any](s []T) {
	for _, v := range s {
		fmt.Println(v)

	}
}
